<template>
  <div class="back-top" @click="backClick" :style="styleObj">
    <img src="~assets/img/common/top.png" alt="">
  </div>
</template>

<script>
  export default {
    name: "",
    props: {
      right: {
        type: String,
        default: '0'
      },
      bottom: {
        type: String,
        default: '0'
      }
    },
    data(){
      return {
        styleObj: { 'right': this.right+'px', 'bottom': this.bottom+'px' }
      }
    },
    methods: {
      backClick(){
        this.$emit('backClick')
      }
    }
  }
</script>

<style lang="less" scoped>
.back-top{
  position: fixed;
  z-index: 20;
  img{
    display: block;
    width: 60px;
  }
}
</style>
